library(readxl)
China <- read_excel("C:/Users/Biniam/Desktop/Documents/Academic/Thesis/Analysis Folder/Excel Files/Iran/China.xlsx")
View(China)
# Importing Data
CHINA <- read_excel("C:/Users/Biniam/Desktop/Documents/Academic/Thesis/Analysis Folder/Excel Files/Iran/China.xlsx")
# Creating Time Series Data
CHINA_ts <- ts(CHINA, start=c(2005,1), end=c(2018,10), frequency=12)
# Viewing and Checking the Created Time Series Data
CHINA_ts
sum(is.na(CHINA_ts))
library(forecast)
CHINA_ts <- tsclean(CHINA_ts)
# Step – 1 of the Box-Jenkins Methodology (Identification: Plotting the Time Series Data)
plot(CHINA_ts)
# Step-2 of the Box-Jenkins Methodology (Estimating the appropriate model)
CHINA_ts_model <- auto.arima(CHINA_ts)
CHINA_ts_model
# Forecasting
options(max.print=1000000)
library(forecast)
CHINA_ts_forecast <- forecast (CHINA_ts_model, level=c(95), h=266)
plot(CHINA_ts_forecast)
CHINA_ts_forecast
write.table(CHINA_ts_forecast, file="China_TSA.csv", sep=",")
# Importing Data
GERMANY <- read_excel("C:/Users/Biniam/Desktop/Documents/Academic/Thesis/Analysis Folder/Excel Files/Iran/Germany.xlsx")
# Creating Time Series Data
GERMANY_ts <- ts(GERMANY, start=c(2004,1), end=c(2018,07), frequency=12)
# Viewing and Checking the Created Time Series Data
GERMANY_ts
sum(is.na(GERMANY_ts))
library(forecast)
GERMANY_ts <- tsclean(GERMANY_ts)
# Step – 1 of the Box-Jenkins Methodology (Identification: Plotting the Time Series Data)
plot(GERMANY_ts)
# Step-2 of the Box-Jenkins Methodology (Estimating the appropriate model)
GERMANY_ts_model <- auto.arima(GERMANY_ts)
GERMANY_ts_model
# Forecasting
options(max.print=1000000)
library(forecast)
GERMANY_ts_forecast <- forecast (GERMANY_ts_model, level=c(95), h=269)
plot(GERMANY_ts_forecast)
GERMANY_ts_forecast
write.table(Germany_ts_forecast, file="Germany_TSA.csv", sep=",")
write.table(GERMANY_ts_forecast, file="Germany_TSA.csv", sep=",")
# Importing Data
GERMANY <- read_excel("C:/Users/Biniam/Desktop/Documents/Academic/Thesis/Analysis Folder/Excel Files/Iran/Germany.xlsx")
# Creating Time Series Data
GERMANY_ts <- ts(GERMANY, start=c(2004,1), end=c(2018,07), frequency=12)
# Viewing and Checking the Created Time Series Data
GERMANY_ts
sum(is.na(GERMANY_ts))
library(forecast)
GERMANY_ts <- tsclean(GERMANY_ts)
# Step – 1 of the Box-Jenkins Methodology (Identification: Plotting the Time Series Data)
plot(GERMANY_ts)
# Step-2 of the Box-Jenkins Methodology (Estimating the appropriate model)
GERMANY_ts_model <- auto.arima(GERMANY_ts)
GERMANY_ts_model
# Forecasting
options(max.print=1000000)
library(forecast)
GERMANY_ts_forecast <- forecast (GERMANY_ts_model, level=c(95), h=269)
plot(GERMANY_ts_forecast)
GERMANY_ts_forecast
write.table(GERMANY_ts_forecast, file="Germany_TSA.csv", sep=",")
# Importing Data
KOREA <- read_excel("C:/Users/Biniam/Desktop/Documents/Academic/Thesis/Analysis Folder/Excel Files/Iran/Korea.xlsx")
# Creating Time Series Data
KOREA_ts <- ts(KOREA, start=c(2008,01), end=c(2018,08), frequency=12)
# Viewing and Checking the Created Time Series Data
KOREA_ts
sum(is.na(KOREA_ts))
library(forecast)
KOREA_ts <- tsclean(KOREA_ts)
# Step – 1 of the Box-Jenkins Methodology (Identification: Plotting the Time Series Data)
plot(KOREA_ts)
# Step-2 of the Box-Jenkins Methodology (Estimating the appropriate model)
KOREA_ts_model <- auto.arima(KOREA_ts)
KOREA_ts_model
# Forecasting
options(max.print=1000000)
library(forecast)
KOREA_ts_forecast <- forecast (KOREA_ts_model, level=c(95), h=268)
plot(KOREA_ts_forecast)
KOREA_ts_forecast
write.table(KOREA_ts_forecast, file="Korea_TSA.csv", sep=",")
# Importing Data
KUWAIT <- read_excel("C:/Users/Biniam/Desktop/Documents/Academic/Thesis/Analysis Folder/Excel Files/Iran/KUWAIT.xlsx")
# Creating Time Series Data
KUWAIT_ts <- ts(KUWAIT, start=c(2008,01), end=c(2017,12), frequency=12)
# Viewing and Checking the Created Time Series Data
KUWAIT_ts
sum(is.na(KUWAIT_ts))
library(forecast)
KUWAIT_ts <- tsclean(KUWAIT_ts)
# Step – 1 of the Box-Jenkins Methodology (Identification: Plotting the Time Series Data)
plot(KUWAIT_ts)
# Step-2 of the Box-Jenkins Methodology (Estimating the appropriate model)
KUWAIT_ts_model <- auto.arima(KUWAIT_ts)
KUWAIT_ts_model
# Forecasting
options(max.print=1000000)
library(forecast)
KUWAIT_ts_forecast <- forecast (KUWAIT_ts_model, level=c(95), h=276)
plot(KUWAIT_ts_forecast)
KUWAIT_ts_forecast
write.table(KUWAIT_ts_forecast, file="Kuwait_TSA.csv", sep=",")
